// 价格管理模块
import PriceRoutes from './price/index.routes.js'

// 内容管理模块
import ContentRoutes from './content/index.routes.js'

// 捎货人模块
import PersonRoutes from './person/index.routes.js'

const Component = {
  name: 'Shaohuo',
  template: '<router-view></router-view>'
}
export default [
  {
    path: '/shaohuo',
    meta: { commonComp: 'container' },
    component: Component,
    children: [
      {
        /* 订单管理
        -------------------------- */
        name: 'ShaohuoOrders',
        path: 'orders',
        meta: { name: '订单管理' },
        component: resolve => require(['./orders'], resolve)
      },
      {
        /* 子加盟商
        -------------------------- */
        name: 'ShaohuoFranchiseeChildren',
        path: 'franchisee-children/:id',
        meta: { name: '子加盟商管理' },
        component: resolve => require(['./franchisee-children'], resolve)
      },
      {
        /* 加盟商
        -------------------------- */
        name: 'ShaohuoFranchisee',
        path: 'franchisee',
        meta: { name: '加盟商管理' },
        component: resolve => require(['./franchisee'], resolve)
      },
      ...PriceRoutes,
      ...ContentRoutes,
      ...PersonRoutes
    ]
  }
]
